package com.mamba.microservice.log;

import lombok.extern.slf4j.Slf4j;

/**
 * Copyright ©2020 360jinrong All Rights Reserved
 * 请添加类/接口的说明：
 *
 * @Package: com.mamba.microservice.log
 * @author: fangjin
 * @date: 2020年04月21日 17时17分
 */
@Slf4j
public class MmsConsumerMonitorLogger {
    /**
     * 打印监控日志
     * |consumer-app|localIp|provider-app|remote-ip|interfaceName#methodName|status|costs|
     *
     * @param logMonitorDomain
     */
    public static void monitorConsumerLog(LogMonitorDomain logMonitorDomain) {
        log.info(logMonitorDomain.getPattern()
                , logMonitorDomain.getConsumerApplication()
                , logMonitorDomain.getConsumerIp()
                , logMonitorDomain.getProviderApp()
                , logMonitorDomain.getProviderIp()
                , logMonitorDomain.getMethodSignature()
                , logMonitorDomain.getStatus()
                , logMonitorDomain.getCostMills());
    }

}
